import React from 'react'
//想要显示二级路由中对应组件的内容，需要从react-router-dom这个包导出一个组件
import { Outlet, NavLink } from 'react-router-dom'
export default function Home() {
    return (
        <div className="panel">
            <div className="panel-body">
                <div>
                    <h2>Home组件内容</h2>
                    <div>
                        <hr />
                        <ul className="nav nav-tabs">
                            <li>
                                <NavLink className="list-group-item" to="/home/news">News</NavLink>
                            </li>
                            <li>
                                <NavLink className="list-group-item " to="/home/message">Message</NavLink>
                            </li>
                        </ul>
                        <hr />
                        <Outlet />
                    </div>
                </div>
            </div>
        </div>
    )
}
